//
//  catreader.h
//  graph-tool
//
//  Created by Armin Lunkeit on 17.02.14.
//  Copyright (c) 2014 Armin Lunkeit. All rights reserved.
//

#ifndef graph_tool_catreader_h
#define graph_tool_catreader_h

#include "../math-core/multigraph.h"
#include "../math-core/fraction.h"

class AttributeVertex : public Vertex
{
public:
    
    AttributeVertex( int id )
    : _id( id )
    {}
    
    inline uint32_t id() const
    { return _id; }
    
protected:
    uint32_t _id;
};

typedef std::shared_ptr<AttributeVertex> PAttributeVertex;

class WeightedEdge : public Edge
{
public:
    WeightedEdge( PFraction weight, PVertex v1, PVertex v2 )
    : Edge( v1, v2 ),
      _weight( weight )
    {}
    
protected:
    PFraction _weight;
};

typedef std::shared_ptr<AttributeVertex> PWeightedEdge;

PMultiGraph initFromCAT( const std::string& file );

#endif
